package com.hospital.dept.yuan.dao;

import com.hospital.dept.yuan.entity.Department;
import com.hospital.dept.yuan.entity.Department_CT;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface DepartmentMapper {
    /**
     * 条件分页查询
     *
     * @param CuserName
     * @return
     */
    List<Department_CT> CtPaging(@Param(value = "CuserName") String CuserName, @Param(value = "CdiagnoseNO") Integer CdiagnoseNO);

    /**
     * 根据诊断id修该排队号
     *
     * @param userid 诊断id
     * @param state  排队号
     * @return
     */
    Integer modify(@Param(value = "userid") Integer userid, @Param(value = "state") Integer state);

    /**
     * 新增Ct
     *
     * @param ct
     * @return
     */
    Integer addCt(Department_CT ct);

    //查询未照片
    List<Department> ctListOne(@Param(value = "id") Integer id,@Param(value = "userName") String userName,@Param(value = "userType") String userType);

    //查询已照片
    List<Department> ctListTwo(String userName);

    //新增ct记录
    int insert(Department_CT department_ct);

    //修改状态
    int update(@Param(value = "userId") String userId,@Param(value = "userTime") String userTime);

    //新增检查情况
    int insertCT(Department_CT department_ct);

    //查询个人历史诊断记录
    List<Department_CT> hiszd(Integer cdiagnoseNO);

}
